import service from '@/utils/request'

const PromoteRuleApi = {
  // ----------------商户推广规则-----------------
  listPromoteRule:function(data){
    return service.get('promoteRule/page', {params:data})
  },
  addPromoteRule:function(data){
    return service.post('promoteRule', data)
  },
  editPromoteRule:function(data){
    return service.put('promoteRule', data)
  },
  updatePromoteRuleState:function(data){
    return service.put('promoteRule/updatePromoteRuleState', data)
  },
  deletePromoteRule:function(data){
    return service.put('promoteRule/delete', data)
  },
  getPromoteRule(data){
    return service.get('promoteRule', {params:data})
  },
  promoteRuleList(data){
    return service.get('promoteRule/listIdName', {params:data})
  },
  promoteProfitList(data){
    return service.get('promoteProfit/listRule', {params:data})
  },
  setPromoteProfit(data){
    return service.post('promoteProfit/setPromoteProfit',data)
  }
}

export default PromoteRuleApi

